<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"  %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'url.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->

  </head>
  
  <body>
  <!-- 
  		JSTL标签库:
  			步骤:
  				1.在页面导入标签库
  				2.在页面使用
  	 
  	 	core 核心库:
  	 		
  	 -->
  	 
  	 <%--
  	 			c:url 生成路径
  	 				value: 生成的url要访问的资源名
  	 				context:资源所在的项目名
  	 				var:路径不会立即显示,而是放到域中.
  	 				scope:指定放到哪个域
  	 			c:param标签 拼装参数
  	 				name : 参数的键
  	 				value: 参数 的值
  	 			
  	  --%>
    <c:url value="/demo1.jsp" context="/day12-jsp/el" var="url" scope="request">
    	<c:param name="name" value="tom"></c:param>
    	<c:param name="age" value="19"></c:param>
    	<c:param name="hehe" value="哈哈"></c:param>
    </c:url>
    
     <a href="${requestScope.url}" >点我</a>
  </body>
</html>
